<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
    <script src="res/js/mui.js"></script>
	<meta http-equiv="Expires" contect="Mon,12 May 2017 00:20:00 GMT">
</head>
<body>
	<div class="mui-content">
		<div class="h150 canhide"></div>
		<div class="login-img">
			<img src="http://localhost/verify.jpg" class="image"/>
		</div>
		<div class="login-input">
			<input id="yzm" class="input-group fm" type="text" maxlength="4" placeholder="请输入验证码"/>
		</div>
		<button class="login-button fm" type="button" value="submit" onclick="submitInfo()" style="width:40px;height:30px; "></button>
	</div>
	<br/>
	<a href="http://localhost/new.php">重新载入</a>
</body>
<script type="text/javascript">
function submitInfo(){
	var yzm = mui('#yzm')[0].value;
	mui.ajax( 'http://localhost/new.php',{
		data: {yzm:yzm,mymodule:'login'},
		dataType:'json',//服务器返回json格式数据
		type:'get',//HTTP请求类型
		timeout:10000,//超时时间设置为10秒；
		success:function(data){
			console.log(data);
		},
		error:function(xhr,type,errorThrown){
			//异常处理；
			console.log('网络错误');
		}
	});
}
</script>
</html>